<template>
	<view style="display: flex;flex-direction: column;align-items: center;">
		<u-image width="140rpx" height="140rpx" :src="src"></u-image>
		<view style="margin-top: 10rpx;font-size: 30rpx;">
			{{skill}}
		</view>
	</view>
</template>

<script>
	export default {
		name: "CourseSkill",
		props: {
			skill: {
				type: String,
				default () {
					return ''
				}
			},
			
			integratedSkill: {
				type: String,
				default () {
					return ''
				}
			}
		},
		data() {
			return {
				src: '',
			}
		},
		mounted() {
			this.init();
		},
		methods: {
			init() {
				const skill = this.$props.skill;
				const integratedSkill = this.$props.integratedSkill;

				if (skill === '精细动作') {
					if (integratedSkill.indexOf(skill) !== -1) {
						// this.src = require("@/pages_teach/static/course_skill_action_press.png");
					} else {
						// this.src = require("@/pages_teach/static/course_skill_action_normal.png");
					}
				}
				
				if (skill === '大肢体运动') {
					if (integratedSkill.indexOf(skill) !== -1) {
						// this.src = require("@/pages_teach/static/course_skill_limbs_press.png");
					} else {
						// this.src = require("@/pages_teach/static/course_skill_limbs_normal.png");
					}
				}
				
				if (skill === '记忆力') {
					if (integratedSkill.indexOf(skill) !== -1) {
						// this.src = require("@/pages_teach/static/course_skill_memory_press.png");
					} else {
						// this.src = require("@/pages_teach/static/course_skill_memory_normal.png");
					}
				}
				
				if (skill === '语言表达') {
					if (integratedSkill.indexOf(skill) !== -1) {
						// this.src = require("@/pages_teach/static/course_skill_language_press.png");
					} else {
						// this.src = require("@/pages_teach/static/course_skill_language_normal.png");
					}
				}
				
				if (skill === '自我服务') {
					if (integratedSkill.indexOf(skill) !== -1) {
						// this.src = require("@/pages_teach/static/course_skill_service_press.png");
					} else {
						// this.src = require("@/pages_teach/static/course_skill_service_normal.png");
					}
				}
				
				if (skill === '自我学习') {
					if (integratedSkill.indexOf(skill) !== -1) {
						// this.src = require("@/pages_teach/static/course_skill_study_press.png");
					} else {
						// this.src = require("@/pages_teach/static/course_skill_study_normal.png");
					}
				}
			}
		}
	}
</script>

<style>
</style>
